/*
 * @Author       : 邱狮杰
 * @Date         : 2021-09-01 11:26:41
 * @LastEditTime : 2021-09-01 11:29:27
 * @FilePath     : /newhope/src/hooks/query.ts
 * @Description  :
 */

import { LocationQueryRaw, useRoute } from 'vue-router'

export type PageQuery<T> = LocationQueryRaw & T

export function useQuery<T>(): [PageQuery<T>] {
	const route = useRoute()
	return [route.query as PageQuery<T>]
}




